//
//  ZLIndexPath.swift
//  ZLPullMenuSwift
//
//  Created by 科大 on 2025/1/16.
//

import UIKit

public class ZLIndexPath: Equatable {
    /// 菜单下标
    public var menuIndex: Int
    
    /// 组下标
    public var groupIndex: Int
    
    /// 选项下标
    public var optionIndex: Int
    
    public init(menuIndex: Int, groupIndex: Int, optionIndex: Int) {
        self.menuIndex = menuIndex
        self.groupIndex = groupIndex
        self.optionIndex = optionIndex
    }
    
    public static func indexPath(_ menuIndex: Int, groupIndex: Int, optionIndex: Int) -> ZLIndexPath {
        return ZLIndexPath(menuIndex: menuIndex, groupIndex: groupIndex, optionIndex: optionIndex)
    }
    
    public static func == (lhs: ZLIndexPath, rhs: ZLIndexPath) -> Bool {
        return lhs.menuIndex == rhs.menuIndex && 
               lhs.groupIndex == rhs.groupIndex && 
               lhs.optionIndex == rhs.optionIndex
    }
}
